#pragma once
#include <atlbase.h>
#include <xmllite.h>

#include <string>
#include <memory>

#include "Element.h"

using std::wstring;

class CActiveX :
	public CElement
{
public:
	CActiveX(void);
	~CActiveX(void);

	virtual void DoFill(IHTMLDocument2* document) throw(...);

protected:
	//wstring _value;
	//wstring _hierarchy;
	//wstring _method;

	//virtual void InitElementFromXml(IXmlReader* pReader) throw(...);
	virtual void BuildAvailableAttributes() throw();
	virtual void ValidateAttributes() const throw(...);

	HWND FindRelativeWnd(IOleInPlaceActiveObject* ipao) const throw(...);
	CComQIPtr<IOleInPlaceActiveObject> GetOleInPlaceActiveObject(IHTMLElement* e) const throw(...);
	void SetText(HWND hwnd) const throw(...);
};

